# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=pymssql
pkgver=2.1.5
pkgrel=3
pkgdesc='A fast MS SQL Server client library for Python directly using C API instead of ODBC. It is Python DB-API 2.0 compliant. Works on Linux, *BSD, Solaris, Mac OS X and Windows.'
arch=('x86_64' 'aarch64')
url='https://pypi.python.org/pypi/pymssql/'
license=('LGPL')
depends=('python2' 'cython2' 'freetds')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$pkgname-$pkgver.tar.gz")
sha512sums=('7cc7336d4c2fcb7c3958fb3127801e3505fd93259d1aaef40a67941ef5aa519e285cdb04fd378c9712f29b0f8a25ce1747a4a8dc21ec57b004c9f0ceb8f5afab')

build() {
  cd "$pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

